package com.example.validated.vo;


import com.example.validated.annotation.EnumValue;
import lombok.AllArgsConstructor;
import lombok.Builder;
import lombok.Data;
import lombok.NoArgsConstructor;

import javax.validation.constraints.NotBlank;

@Data
@AllArgsConstructor
@NoArgsConstructor
@Builder
public class MemberDTO {

    @NotBlank(message = "姓名不能为空")
    private String name;

    @EnumValue(intValues = {0, 1, 2}, message = "性别值非法，0：男，1：女，2：其他")
    private Integer sex;
}
